package world.criver.h50909.service;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import world.criver.h50909.dao.daoQuery;
import world.criver.h50909.entity.entEquipmentInfo;
import world.criver.h50909.entity.entModelInfo;
import world.criver.h50909.entity.entName;
import world.criver.h50909.response.resEquipmentSummaryList;
import world.criver.h50909.response.resModelNameList;
import world.criver.h50909.response.resModelSummaryList;
import world.criver.h50909.tool.toolEquipmentInfo;
import world.criver.h50909.tool.toolModelInfo;
@Service
public class serQuery implements daoQuery{
    @Autowired
    private toolEquipmentInfo toolEquipmentInfo;
    @Autowired
    private toolModelInfo toolModelInfo;
    @Override
    public resModelNameList queryModelNameList() {
        return null;
    }

    @Override
    public resEquipmentSummaryList queryEquipmentSummaryList() {
        return new resEquipmentSummaryList(toolEquipmentInfo.querySummaryList(),true);
    }

    @Override
    public resModelSummaryList queryModelSummaryList() {
        return new resModelSummaryList(toolModelInfo.summaryList(),true);
    }

    @Override
    public entEquipmentInfo queryEquipmentInfo(entName info) {
        return toolEquipmentInfo.info(info.getName());
    }

    @Override
    public entModelInfo queryModelInfo(entName info) {
        return toolModelInfo.info(info.getName());
    }
}
